package com.zerous.staria.screens;

import com.zerous.framework.*;
import com.zerous.staria.*;
import com.zerous.framework.ui.*;
import android.os.*;

public class TestScreen extends LayoutScreen
{
	public TestScreen(Game g, Screen p, String l)
	{
		super(g, p);
		bindLayout(l);
		Button btn2 = (Button)getUI("btn2");
		Button btn = (Button)getUI("btn1");
		btn2.setOnClick(new UIBase.OnClick() {
			public void click()
			{
				/*
				Message m = game.getGameHandler().obtainMessage();
				
				Bundle b2 = new Bundle();
				b2.putString("text", "getString");
				m.setData(b2);
				game.getGameHandler().sendMessage(m);
				*/
				Util.editText(game);
			}
		});
		
		btn.setOnClick(new UIBase.OnClick() {
			public void click()
			{
				/*Message m = game.getGameHandler().obtainMessage();
				Bundle b = new Bundle();
				b.putString("toast", game.getStrBuff());
				m.setData(b);
				game.getGameHandler().sendMessage(m);*/
				Util.toast(game, game.getStrBuff());
			}
		});
	}

	@Override
	public void render()
	{
		// TODO: Implement this method
		Zex.graphics.clear(0xffffffff);
		drawWigets();
		Zex.graphics.drawText(Zex.Const.px + " " + Zex.Const.width / Zex.Const.px, 500, 500);
		Util.drawPixel(600, 600);
	}
}
